package com.javaee.term.service.iml;

import com.javaee.term.mapper.LogistInfoMapper;
import com.javaee.term.model.LogistInfo;
import com.javaee.term.service.LogistInfoService;
import com.javaee.term.service.base.BaseServiceIml;
import org.springframework.stereotype.Service;

import java.util.List;

/**
 * author 陈伯瑞
 * date 2019/12/18 0018 12:50
 * version 1.0
 **/
@Service
public class LogistInfoServiceImpl  extends BaseServiceIml implements LogistInfoService {
    @Override
    public LogistInfo findOne(Object id) {
        return logistInfoMapper.selectByPrimaryKey(id);
    }

    @Override
    public List<LogistInfo> findAll() {
        return logistInfoMapper.selectAll();
    }

    @Override
    public void delete(Object id) {
     logistInfoMapper.deleteByPrimaryKey(id);
    }

    @Override
    public int insert(LogistInfo logistInfo) {
        return logistInfoMapper.insert(logistInfo);
    }

    @Override
    public int update(LogistInfo logistInfo) {
        return logistInfoMapper.updateByPrimaryKey(logistInfo);
    }

    @Override
    public LogistInfo findBySendId(String sendId) {
        return  logistInfoMapper.selectBySendId(sendId);
    }
}
